package edu.hawaii.ics314.ical.view;

import java.util.Objects;

public class ViewEvent<T> {
	
	private final View<T> SOURCE;
	private final T RESULT;
	private final int INDEX;
	
	public ViewEvent(View<T> source, T result, int index) {
		SOURCE = Objects.requireNonNull(source);
		RESULT = result;
		INDEX = index;
	}
	
	public View<T> getSource() {
		return SOURCE;
	}

	public T getResult() {
		return RESULT;
	}
	
	public int getIndex() {
		return INDEX;
	}

}
